/*
依据题意找出规律即可
*/
#include<iostream>
#include<string>
#include<string.h>
#include<vector>
#include<cstdio>
#include<algorithm>
#include<map>
#include<set>
#include<cmath>
using namespace std;
#define int long long
#define pi acos(-1)

int r,y,b;

inline int func(int u)
{
	if(u>=2) return 2;
	return u;
}
inline void book()
{
	int score = func(r) + func(y) + func(b);
	int ans = 0;
	
	for(int i=0;i<score;++i) ans += i;
	
	if(r+y+b>score) ans += (r+y+b-score)*score;
	
	cout<<ans<<endl;
}


signed main()
{
	while(cin>>r>>y>>b)
	{
		book();
	}
	return 0;
}
